﻿namespace MicroCloud.Authorization.Entities
{
    /// <summary>
    /// 实体类：模块信息
    /// </summary>
    [Table(nameof(Module), Schema = TableSchemaConstants.Authorization)]
    [Description("模块信息")]
    [ValueGenerate(ValueGenerateRule.Never, ValueGenerateMode.Snowflake)]
    public class Module : ModuleBase<long>
    {
        #region "属性"
        // 导航属性
        #region "获取或设置 父模块信息"
        /// <summary>
        /// 获取或设置 父模块信息
        /// </summary>
        [JsonIgnore]
        public virtual Module Parent { get; set; }
        #endregion
        #region "获取或设置 子模块信息集合"
        /// <summary>
        /// 获取或设置 子模块信息集合
        /// </summary>
        public virtual ICollection<Module> Children { get; set; } = new List<Module>();
        #endregion

        #endregion

    }

}
